<?php

namespace App\Http\Controllers;

use App\Course;
use Illuminate\Http\Request;

class CourseController extends Controller
{
    public function index(){
        $data = Course::all();
        return json_decode(json_encode($data),true);
    }
}
